package com.tn.exam.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * ExamAnswer entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "exam_answer")
public class ExamAnswer extends BaseEntity implements java.io.Serializable {

	// Fields

	private Integer answerId;
	private Integer answerExamId;
	private Integer answerUserId;
	private Integer answerQuestionId;
	private Integer answerQuestionType;
	private String answerQuestionAnswer;
	private Integer answerQuestionScore;
	private Integer answerScore;

	// Constructors

	/** default constructor */
	public ExamAnswer() {
	}

	/** minimal constructor */
	public ExamAnswer(Integer answerExamId, Integer answerUserId,
			Integer answerQuestionId, Integer answerQuestionType,
			String answerQuestionAnswer, Integer answerScore) {
		this.answerExamId = answerExamId;
		this.answerUserId = answerUserId;
		this.answerQuestionId = answerQuestionId;
		this.answerQuestionType = answerQuestionType;
		this.answerQuestionAnswer = answerQuestionAnswer;
		this.answerScore = answerScore;
	}

	/** full constructor */
	public ExamAnswer(Integer answerExamId, Integer answerUserId,
			Integer answerQuestionId, Integer answerQuestionType,
			String answerQuestionAnswer, Integer answerQuestionScore,
			Integer answerScore) {
		this.answerExamId = answerExamId;
		this.answerUserId = answerUserId;
		this.answerQuestionId = answerQuestionId;
		this.answerQuestionType = answerQuestionType;
		this.answerQuestionAnswer = answerQuestionAnswer;
		this.answerQuestionScore = answerQuestionScore;
		this.answerScore = answerScore;
	}

	// Property accessors
	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "answer_id", unique = true, nullable = false)
	public Integer getAnswerId() {
		return this.answerId;
	}

	public void setAnswerId(Integer answerId) {
		this.answerId = answerId;
	}

	@Column(name = "answer_exam_id", nullable = false)
	public Integer getAnswerExamId() {
		return this.answerExamId;
	}

	public void setAnswerExamId(Integer answerExamId) {
		this.answerExamId = answerExamId;
	}

	@Column(name = "answer_user_id", nullable = false)
	public Integer getAnswerUserId() {
		return this.answerUserId;
	}

	public void setAnswerUserId(Integer answerUserId) {
		this.answerUserId = answerUserId;
	}

	@Column(name = "answer_question_id", nullable = false)
	public Integer getAnswerQuestionId() {
		return this.answerQuestionId;
	}

	public void setAnswerQuestionId(Integer answerQuestionId) {
		this.answerQuestionId = answerQuestionId;
	}

	@Column(name = "answer_question_type", nullable = false)
	public Integer getAnswerQuestionType() {
		return this.answerQuestionType;
	}

	public void setAnswerQuestionType(Integer answerQuestionType) {
		this.answerQuestionType = answerQuestionType;
	}

	@Column(name = "answer_question_answer", nullable = false)
	public String getAnswerQuestionAnswer() {
		return this.answerQuestionAnswer;
	}

	public void setAnswerQuestionAnswer(String answerQuestionAnswer) {
		this.answerQuestionAnswer = answerQuestionAnswer;
	}

	@Column(name = "answer_question_score")
	public Integer getAnswerQuestionScore() {
		return this.answerQuestionScore;
	}

	public void setAnswerQuestionScore(Integer answerQuestionScore) {
		this.answerQuestionScore = answerQuestionScore;
	}

	@Column(name = "answer_score", nullable = false)
	public Integer getAnswerScore() {
		return this.answerScore;
	}

	public void setAnswerScore(Integer answerScore) {
		this.answerScore = answerScore;
	}

}